using UnityEngine;
namespace Client.Hotfix
{
    public abstract class BaseModule
    {
        protected GameModule GameModule { get; private set; }
        public BaseModule(GameModule gameModule)
        {
            GameModule = gameModule;
        }
        public virtual void OnEnter() { }
        public virtual void OnExit() { }

        protected void Next<T>() where T : BaseModule
        {
            GameModule?.EnterModule<T>();
        }

    }

}
